package com.easy.dev.aop;

import com.easy.dev.entity.Log;
import com.easy.dev.manager.Handler;
import com.easy.dev.service.impl.LogServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
public class HandlerLog implements Handler<Log> {

    @Autowired
    private LogServiceImpl logService;

    @Override
    public void handlerData(List<Log> datas) {
        logService.saveBatch(datas,datas.size());
    }

}

